//
//  ICMCustomInfoCell.m
//  ICrEAM
//
//  Created by wangbing on 16/12/12.
//  Copyright © 2016年 mac. All rights reserved.
//

#import "ICMCustomInfoCell.h"

@implementation ICMCustomInfoCell
+(instancetype)createICMCustomInfoCell{
    return [[[NSBundle mainBundle]loadNibNamed:@"ICMCustomInfoCell" owner:nil options:nil]lastObject];
}
- (void)awakeFromNib {
    [super awakeFromNib];
    self.selectionStyle=UITableViewCellSelectionStyleNone;
    if (![ICrEAMTool isVW]) {
        self.contentView.backgroundColor = KSKBgColor;
    }
    // Initialization code
}
- (IBAction)selectedBtn:(UIButton *)sender {
    sender.selected=!sender.selected;
    if (self.selectedBlock) {
        self.selectedBlock(self.indexPath.row,sender.selected);
    }
}
-(void)setModel:(RelectiveAppointMentModel *)model{
    _model=model;
    self.repireType.text =model.BOOKING_REPAIR_TYPE_NAME;
    
    self.repireDate.text =model.BOOKING_COME_TIME;
    
    self.repireID.text =model.BOOKING_ORDER_NO;
//    self.selectBtn.selected=model.isSelect;
      NSString *imageName=@"unselect_img";
    if (model.isSelect) {
       imageName = [ICrEAMTool isVW]?@"selected_img":@"sk_appoint_link_icon";
    }
    else
    {
        imageName = @"unselect_img";
    }
    [self.selectBtn setImage:[UIImage imageNamed:imageName] forState:UIControlStateNormal];
    
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
